/*
Copyright [2023] [fuwen_soft]
*/
package vip.xiaonuo.modular.xypdf.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.NoArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import vip.xiaonuo.core.pojo.base.entity.BaseEntity;
import io.swagger.annotations.ApiModel;
import java.time.LocalDateTime;
import java.time.LocalDate;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.*;
import cn.afterturn.easypoi.excel.annotation.Excel;
import vip.xiaonuo.modular.xylogy.entity.XyLogy;
import vip.xiaonuo.modular.xypdf.form.PdfLogyGenderForm;

/**
 * 谱书
 *
 * @author yanwei
 * @date 2023-05-05 15:44:28
 */
@EqualsAndHashCode(callSuper = true)
@Data
@TableName("xy_pdf")
@ApiModel("xy_pdf 实体")
@NoArgsConstructor
public class XyPdf extends BaseEntity {

    public XyPdf(String userId,PdfLogyGenderForm pdfLogyGenderForm, String pdfUrl){
        this.userId = userId;
        this.logyId = pdfLogyGenderForm.getLogyId();
        this.templateId = pdfLogyGenderForm.getTemplateId();
        this.author = pdfLogyGenderForm.getAuthor();
        this.hallHost = pdfLogyGenderForm.getHallHost();
        this.rollHost = pdfLogyGenderForm.getRollHost();
        this.headName  = pdfLogyGenderForm.getHeadName();
        this.pdfUrl = pdfUrl;
    }

    /**
     * 
     */
    @ApiModelProperty("")
    @TableId(type = IdType.ASSIGN_ID)
    private String id;


    /**
     * 模板编号
     */
    @Excel(name = "模板编号")
    @ApiModelProperty("模板编号")
    private String templateId;


    /**
     * 家谱编号
     */
    @Excel(name = "家谱编号")
    @ApiModelProperty("家谱编号")
    private String logyId;


    /**
     * 创建人的用户编号
     */
    @Excel(name = "创建人的用户编号")
    @ApiModelProperty("创建人的用户编号")
    private String userId;


    /**
     * 编者
     */
    @Excel(name = "编者")
    @ApiModelProperty("编者")
    private String author;


    /**
     * 堂号
     */
    @Excel(name = "堂号")
    @ApiModelProperty("堂号")
    private String hallHost;


    /**
     * 卷号
     */
    @Excel(name = "卷号")
    @ApiModelProperty("卷号")
    private String rollHost;


    /**
     * 页眉谱名
     */
    @Excel(name = "页眉谱名")
    @ApiModelProperty("页眉谱名")
    private String headName;

    /**
     * 页眉谱名
     */
    @Excel(name = "资源链接")
    @ApiModelProperty("资源链接")
    private String pdfUrl;


    /**
     * 页眉谱名
     */
    @Excel(name = "资源链接")
    @ApiModelProperty("资源链接")
    private String pdfLink;


    @TableField(exist = false)
    private XyLogy xyLogy;


}
